package gao.xiaolei.entity;

import java.time.LocalDateTime;
import javax.persistence.Column;
import javax.persistence.Entity;

import lombok.Data;
import com.fasterxml.jackson.annotation.JsonInclude;

@Entity
@JsonInclude(JsonInclude.Include.NON_EMPTY)
@Data
public class TestRequirementCheck extends TestCheckBase {

    @Column(columnDefinition = "char(32)")
    private String parentId;//形成树结构的父节点

    @Column
    private Integer leaf;//形成树节点判断是否是叶子节点

    public TestRequirementCheck(String id, String targetId, String checkMan, String annotate, int isPass, int isFinish, LocalDateTime checkDate, String parentId, Integer leaf, String projectId) {
        super(id, targetId, checkMan, annotate, isPass, isFinish, checkDate, projectId);
        this.parentId = parentId;
        this.leaf = leaf;
    }

    public TestRequirementCheck(String id, String targetId,
                                String checkMan, String annotate, int isPass, int isFinish,
                                LocalDateTime checkDate) {
        super();
        this.id = id;
        this.targetId = targetId;
        this.checkMan = checkMan;
        this.annotate = annotate;
        this.isPass = isPass;
        this.checkDate = checkDate;
        this.isFinish = isFinish;
    }

    public TestRequirementCheck(String id, String targetId,
                                LocalDateTime checkDate) {
        super();
        this.id = id;
        this.targetId = targetId;
        this.checkDate = checkDate;
    }

    public TestRequirementCheck(String id, String targetId, int isPass,
                                LocalDateTime checkDate) {
        super();
        this.id = id;
        this.targetId = targetId;
        this.isPass = isPass;
        this.checkDate = checkDate;
    }

    public TestRequirementCheck(String id, String targetId, int isPass,
                                LocalDateTime checkDate, Integer leaf, String parentId) {
        super();
        this.id = id;
        this.targetId = targetId;
        this.isPass = isPass;
        this.checkDate = checkDate;
        this.leaf = leaf;
        this.parentId = parentId;
    }

    public TestRequirementCheck(String id, int isPass, String checkMan,
                                int isFinish, LocalDateTime checkDate) {
        super();
        this.id = id;
        this.checkMan = checkMan;
        this.isPass = isPass;
        this.checkDate = checkDate;
        this.isFinish = isFinish;
    }


    public TestRequirementCheck() {
        super();
    }

}
